import request from '@/utils/request'

// 查询牛奶会员卡列表
export function listMemberMilkCard (query) {
  return request({
    url: '/system/memberMilkCard/list',
    method: 'get',
    params: query
  })
}

// 查询牛奶会员卡详细
export function getMemberMilkCard (id) {
  return request({
    url: '/system/memberMilkCard/' + id,
    method: 'get'
  })
}

// 新增牛奶会员卡
export function addMemberMilkCard (data) {
  return request({
    url: '/system/memberMilkCard',
    method: 'post',
    data: data
  })
}

// 修改牛奶会员卡
export function updateMemberMilkCard (data) {
  return request({
    url: '/system/memberMilkCard',
    method: 'put',
    data: data
  })
}

export function updateCardStatus (data) {
  return request({
    url: '/system/memberMilkCard/updateCardStatus',
    method: 'post',
    data: data
  })
}

// 删除牛奶会员卡
export function delMemberMilkCard (id) {
  return request({
    url: '/system/memberMilkCard/' + id,
    method: 'delete'
  })
}
